﻿<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@ include file="/static/include/top.jsp"%>
<script>document.title="消息管理";</script>
<script type="text/javascript">
function getList(){
	var url="${baseURL}/monitor/pm";
	window.location.href(url);
}
function openViewWin(id){
	openWin("查看详情","${baseURL}/monitor/pmdetail?id="+id,600,500);
	//window.open("${baseURL}/monitor/pmdetail?id="+id, "viewwindow", "width=500,height=600")
}
function sendMes(){
	openWin("发送消息","${baseURL}/monitor/sendMes",600,700);
	//window.open("sendMes", "newwindow", "width=500,height=600")
}
function closeLayerWin(){
	layer.closeAll();
}
</script>
  <table>
  <tbody>
   <tr>
			<th><img src="${ctx}/static/images/pages/cen/rig/ico_01.png"
				align="absmiddle">&nbsp;消息管理</th>
	</tr>
    <tr>
    <td>
    	<form name="searchForm" action="" method="get">
    	<input type="hidden" name="p" value="1" />
		<a class="tab_but" href="#" onclick="getList();return false;">刷新</a>
		<a class="tab_but" href="#" onclick="sendMes();return false;">发送新消息</a>
		</form>
    </td>
    </tr>
    </tbody>
  </table>
  <br />
	<c:if test="${empty obj.operationResult}">
		<b>没有符合条件的记录。</b>
	</c:if>
<c:if test="${not empty obj.operationResult}">
  <table id="listTable">
  <tbody>
    <tr>
    	<th width="5%">序号</th>
    	<th width="20%">发送人</th>
        <th width="30%">标题</th>
		<th width="20%">发送时间</th>
		<th width="15%">状态</th>
		<th>操作</th>
    </tr>
    <c:forEach var="oneRow" items="${obj.operationResult}" varStatus="status">
    		
    <tr>
    	<td align="left">${status.index+1}</td>
      	<td align="left">${oneRow.pmFromName}</td>
		<td align="left">${oneRow.title}</td>
		<td align="left">${oneRow.sendTime}</td>
		<td align="left">${oneRow.isRead==1?'已读':'未读'}</td>
		<td align="left">
			<a href="#" onclick="openViewWin('${oneRow.id}')"><img src="${baseURL}/static/images/tab/ico_01.png" width="16" height="16" border="0" align="absmiddle"/>查看</a>
		</td>
    </tr>
    </c:forEach>
    <tr class="tab_grey">
				<td colspan="9" align="center" valign="middle" class="tab_white">
				<div class="pagination"> 
					<%@ include file="../include/listpage.jsp"%>
				</div>
				<div class="clear"></div>
				</td>
			</tr>
    </tbody>
  </table>
</c:if>

<%@ include file="/static/include/bottom.jsp"%>
